import { BrowserRouter, Routes, Route } from 'react-router-dom';
import { App } from './App';
import { ReviewPage } from './components/ReviewPage';
import { GuidesPage } from './pages/GuidesPage';
import { AboutPage } from './pages/AboutPage';
import { ContactPage } from './pages/ContactPage';
import { PrivacyPage } from './pages/PrivacyPage';
import { TermsOfServicePage } from './pages/TermsOfServicePage';
import { AffiliateDisclosurePage } from './pages/AffiliateDisclosurePage';
import { TopPicksPage } from './pages/TopPicksPage';
import { Layout } from './components/Layout';
import { ReviewsListPage } from './pages/ReviewsListPage';

export function AppRouter() {
  return <BrowserRouter>
      <Routes>
        <Route path="/" element={<App />} />
        <Route path="/reviews" element={<Layout>
              <ReviewsListPage />
            </Layout>} />
        <Route path="/reviews/:productSlug" element={<Layout>
              <ReviewPage />
            </Layout>} />
        <Route path="/top-picks" element={<Layout>
              <TopPicksPage />
            </Layout>} />
        <Route path="/guides" element={<Layout>
              <GuidesPage />
            </Layout>} />
        <Route path="/about" element={<Layout>
              <AboutPage />
            </Layout>} />
        <Route path="/contact" element={<Layout>
              <ContactPage />
            </Layout>} />
        <Route path="/privacy-policy" element={<Layout>
              <PrivacyPage />
            </Layout>} />
        <Route path="/terms-of-service" element={<Layout>
              <TermsOfServicePage />
            </Layout>} />
        <Route path="/affiliate-disclosure" element={<Layout>
              <AffiliateDisclosurePage />
            </Layout>} />
      </Routes>
    </BrowserRouter>;
}